﻿using Utils;
using static DataModels.Enums.GeneralEnum;

namespace DataModels.Dto.Community
{
    public class GetPropertyAnnouncementResponse
    {
        public Guid UUID { get; set; }
        public Guid ProjectUUID { get; set; }

        //public string UUID { get; set; }
        //public string ProjectUUID { get; set; }

        /// <summary>
        /// 标题
        /// </summary>
        public string Title { get; set; }

        /// <summary>
        /// 首图
        /// </summary>
        public string Image { get; set; }

        /// <summary>
        /// 内容
        /// </summary>
        public string Content { get; set; }

        /// <summary>
        /// 浏览量
        /// </summary>
        public int PageView { get; set; }

        /// <summary>
        /// 是否已读
        /// </summary>
        public Status IsRead { get; set; }

        /// <summary>
        /// 是否点赞
        /// </summary>
        public Status IsLike { get; set; }

        /// <summary>
        /// 是否订阅
        /// </summary>
        public Status IsSubscribe { get; set; }

        public int LikesCount { get; set; }
        public int CommentCount { get; set; }

        /// <summary>
        /// 是否置顶
        /// </summary>
        public int IsTop { get; set; }
    }

    public class PropertyAnnouncementRequest : PageRequest
    {
        /// <summary>
        /// 公告ID
        /// </summary>
        [GeneralRequired]
        public Guid PropertyAnnouncementUUID { get; set; }
    }

    public class GetPropertyAnnouncementiInfo : PageRequest
    {
        public Guid? ProjectUUID { get; set; }
        //public string ProjectUUID { get; set; }
    }

    public class CreatePropertyAnnouncementCommentsInfo
    {
        /// <summary>
        /// 父级评论ID
        /// </summary>
        public Guid? ParentCommentUUID { get; set; }

        /// <summary>
        /// 公告ID
        /// </summary>
        [GeneralRequired]
        public Guid PropertyAnnouncementUUID { get; set; }

        /// <summary>
        /// 内容
        /// </summary>
        public string Content { get; set; }

        /// <summary>
        /// 图片Url
        /// </summary>
        public List<string> Urls { get; set; }
    }

    public class GetPropertyAnnouncementComments
    {
        public Guid PropertyAnnouncementCommentsUUID { get; set; }

        public string Content { get; set; }

        public Guid CreateUserUUID { get; set; }

        public string CreateUserName { get; set; }

        public DateTime CreateTime { get; set; }

        public List<string> Images { get; set; }
        public List<GetPropertyAnnouncementComments> Children { get; set; }

    }
}
